<template>
  <div>
    <!--$route.params对象访问到动态匹配的参数值  -->
    <h3>MyMovie 组件 --- {{$route.params.mid}}--- {{ mid }}</h3>
    <button type="button" class="btn btn-danger" @click="goBack">后退</button>
  </div>
</template>

<script>
export default {
  name: 'MyMovie',
  props: ['mid'],
  methods: {
    goBack() {
      // 回退到上一个组件页面
      this.$router.go(-1)
    }
  }
}
</script>

<style lang="less" scoped></style>
